package juc.lock.sync;

/**
 * 教程链接：
 * https://pdai.tech/md/java/thread/java-thread-x-key-synchronized.html
 */
public class SynchronizedDemo2 {


    Object object = new Object();

    public void method1(){

        synchronized (object){

        }
        method2();
    }

    public void method2(){

    }

}
